package com.wing.purchase.service;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.IService;
import com.wing.purchase.model.entity.PurchaseQuotation;
import com.wing.purchase.model.request.PurchaseQuotationForm;
import com.wing.purchase.model.response.PurchaseQuotationVO;

import java.util.List;
import java.util.Map;

/**
 * 报价单-Service
 *
 * @author
 */
public interface PurchaseQuotationService extends IService<PurchaseQuotation> {

    /**
     * 添加
     *
     * @param purchaseQuotationForm
     * @return
     */
    int add(PurchaseQuotationForm purchaseQuotationForm);

    /**
     * 列表-app
     *
     * @param params
     *
     * @return
     */
    List<PurchaseQuotationVO> list4app(Map<String, Object> params);

    /**
     * 分页list-app
     *
     * @param page
     * @param params
     *
     * @return
     */
    Page<PurchaseQuotationVO> pageList4app(Page page, Map<String, Object> params);

    /**
     * 详情-app
     *
     * @param id
     *
     * @return
     */
    PurchaseQuotationVO get4appById(Long id);

    /**
     * 驳回报价单
     * @param id
     * @return
     */
    int reject(Long id);

    /**
     * 确认报价单
     * @param id
     * @return
     */
    int confirm(Long id);

    /**
     * 取消确认
     * @param id
     * @return
     */
    int cancel(Long id);
}
